package com.bookocean.application.service;

import com.bookocean.controller.dto.DailyQuoteResultDto;
import com.bookocean.domain.service.DailyQuoteDomainService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

/**
 * 每日一句应用服务
 * 
 * @author BookOcean
 * @since 2024-01-01
 */
@Service
@RequiredArgsConstructor
public class DailyQuoteApplicationService {

    private final DailyQuoteDomainService dailyQuoteDomainService;

    /**
     * 获取每日一句
     */
    public DailyQuoteResultDto getDailyQuote(Long userId) {
        return dailyQuoteDomainService.getDailyQuote(userId);
    }

    /**
     * 提交答案
     */
    public DailyQuoteResultDto submitAnswer(Long quizId, String userId, String answer) {
        return dailyQuoteDomainService.submitAnswer(quizId, userId, answer);
    }
}
